package com.github.prontera.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import com.github.prontera.StatusCode;
import com.github.prontera.aspect.HibernateValidatorAspect;

/**
 * @author Alex
 */
@Configuration
public class AopConfiguration {

	@Bean
	public HibernateValidatorAspect hibernateValidatorAspect() {
		final int order = Byte.MAX_VALUE + 2;
		return new HibernateValidatorAspect(order, StatusCode.INVALID_MODEL_FIELDS);
	}

}
